package Controller;
import java.util.ArrayList;
import junit.framework.TestCase;
import org.junit.*;

public class GuestManageIntegrationTester extends TestCase {
	private  GuestManageController controller;
	@Before
	protected void setUp() throws Exception {
		super.setUp();
		controller=new GuestManageController();
	}

	@After
	protected void tearDown() throws Exception {
		super.tearDown();
	}

	@Test
	public void testGiveDiscount(){
		long id1=1;long id2=2;long id3=3;
		ArrayList<Long> disID=new ArrayList<Long>();
		disID.add(id1);disID.add(id2);disID.add(id3);
		boolean isSucceed=controller.giveDiscount(10, disID);
		assertEquals(true,isSucceed);
	}
	@Test
	public void testGiveEx(){
		long id1=1;long id2=2;long id3=3;
		ArrayList<Long> disID=new ArrayList<Long>();
		disID.add(id1);disID.add(id2);disID.add(id3);
		
		int num1=1;int num2=2;int num3=3;
		ArrayList<Integer> num=new ArrayList<Integer>();
		num.add(num1);num.add(num2);num.add(num3);
		
		boolean isSucceed=controller.giveEx(10, disID, num);
		assertEquals(true,isSucceed);
	}
}
